//
//  RightMaterialTableViewCell.m
//  OrderAssistant
//
//  Created by chendong on 2020/8/26.
//  Copyright © 2020 chendong. All rights reserved.
//

#import "RightMaterialTableViewCell.h"

@implementation RightMaterialTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.backgroundColor = [UIColor clearColor];
        self.selectionStyle = UITableViewCellSelectionStyleNone;
        
        UILabel *nameL = [[UILabel alloc]initWithFrame:CGRectMake(0, 0, 100, 50)];
        nameL.text = @"蔬菜";
        nameL.font = [UIFont systemFontOfSize:16];
        nameL.textColor = [UIColor blackColor];
        nameL.textAlignment = NSTextAlignmentCenter;
        nameL.numberOfLines = 0;
        nameL.backgroundColor = RGBCOLOR(209, 209, 209);
        [self.contentView addSubview:nameL];
        self.nameL = nameL;
        
        UILabel *numL = [[UILabel alloc]initWithFrame:CGRectMake(0, 0, 20, 20)];
        numL.center = CGPointMake(nameL.frame.size.width-10, 10);
        numL.backgroundColor = RGBCOLOR(251, 62, 31);
        numL.layer.cornerRadius = 10;
        numL.clipsToBounds = YES;
        numL.textColor = [UIColor whiteColor];
        numL.hidden = YES;
        numL.textAlignment = NSTextAlignmentCenter;
        [self.contentView addSubview:numL];
        self.numL = numL;
        
    }
    return self;
}

@end
